package br.com.iswe.gwt.manter.client;

import java.util.List;
import java.util.Map;

import br.com.iswe.gwt.util.client.QueryInfo;
import br.com.iswe.gwt.util.client.RequestInfo;
import br.com.iswe.gwt.util.client.SessionInfo;

import com.google.gwt.user.client.rpc.RemoteService;

public interface ManterService extends RemoteService {

	/**
	 * @gwt.typeArgs listaRequest <br.com.iswe.gwt.util.client.RequestInfo>
	 * @gwt.typeArgs <java.lang.String>
	 * 
	 * @param listaRequest
	 * @param requestInfo
	 * @return
	 * @throws ISWERpcException
	 */
	List consultar(List listaRequest, RequestInfo requestInfo) throws ISWERpcException;
	
	List consultar(String controllerName, Map filtro, QueryInfo pageInfo) throws ISWERpcException;
	
	Map detalhar(String controllerName, Map filtro, RequestInfo requestInfo) throws ISWERpcException;
	
	Map salvar(String controllerName, Map bean, RequestInfo requestInfo) throws ISWERpcException;
	
	Map deletar(String controllerName, Map bean, RequestInfo requestInfo) throws ISWERpcException;
	
	SessionInfo getSessionInfo(String controllerName) throws ISWERpcException;
	
	Map executeMap(String controllerName, String methodName, Map mapBean, RequestInfo requestInfo) throws ISWERpcException;
	List executeList(String controllerName, String methodName, Map mapBean, RequestInfo requestInfo) throws ISWERpcException;
	
	Map associarManyToMany(String controllerName, Map bean, RequestInfo requestInfo) throws ISWERpcException;
	Map removerManyToMany(String controllerName, Map bean, RequestInfo requestInfo) throws ISWERpcException;

	SessionInfo efetuarLogin(String controllerName, Map bean) throws ISWERpcException;
	void efetuarLogout(String controllerName) throws ISWERpcException;
	
	
	
}
